<!DOCTYPE html>
<html>

<head>
  <title>Your Web Page</title>
</head>

<body>
  <button onclick="callBackSuccess()">Call Native Method</button>

  <script>
    function callBackSuccess() {
      window.postMessage(JSON.stringify({
        nativeMethod: 'callBackSuccess',
        data: '回调'
      }));
    }
  </script>
</body>

</html>